package com.itheima.tanhua.dubbo.api;


import com.itheima.tanhua.dubbo.mappers.MovementsMapper;
import com.itheima.tanhua.dubbo.mappers.UserMapper;
import com.itheima.tanhua.model.dto.MovementsDto;
import org.apache.dubbo.config.annotation.DubboService;
import org.springframework.beans.factory.annotation.Autowired;

import java.util.List;

@DubboService
public class MovementsServiceImpl implements MovementsService{
    @Autowired
    private MovementsMapper movementsMapper;

    @Override
    public void saveMovement(MovementsDto movementsDto) {
        movementsMapper.saveMovement(movementsDto);
    }

    @Override
    public List<Integer> getFriends(Integer id) {
        return movementsMapper.getFriends(id);
    }

    @Override
    public List<Long> getMovementId(Long id) {
        return movementsMapper.getMovementId(id);
    }

    @Override
    public void saveMovementTimeLine(Integer friend, Integer id, Long mid) {
        movementsMapper.saveMovementTimeLine(friend,id,mid);
    }
}
